<?php
namespace app\shop\validate;
use think\Validate;

class GoodsValidate extends Validate
{
    protected $rule = [
        'goods_sn|产品编码' => 'require|unique:goods,goods_sn',
		'goods_name|产品名称' => 'require',
    ];
	
    protected $message = [

    ];

    //验证场景
    protected $scene = [
        'addgoods' => ['goods_sn','goods_name'],
    ];
}